package com.appkubes.fintech.admin.application.risk.data.xingpan.controller;

import com.appkubes.fintech.admin.application.risk.data.xingpan.service.XingPanRiskOtherService;
import com.appkubes.fintech.common.response.Response;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * 类名: XingPanOtherController
 * 描述: TODO
 * 日期: 2020/5/4 17:08
 *
 * @author Reboot65
 * @version 1.0
 **/
@Slf4j
@RestController
@Api(tags = "星盘运营商数据扩展")
@RequestMapping("/risk/xingpanOther")
public class XingPanOtherController {

    @Resource
    private XingPanRiskOtherService xingPanRiskOtherService;

    @ApiOperation("爬取数据")
    @GetMapping("/crawlerData")
    public Response crawlerData(String userKey, String phone, String pass) {
        return xingPanRiskOtherService.crawlerData(userKey,phone,pass);
    }

    @ApiOperation("填写验证码")
    @GetMapping("/appendData")
    public Response appendData(String userKey,String name,String code,String crawlerId ,String crawlerToken) {
        return xingPanRiskOtherService.appendData(userKey,name,code,crawlerId,crawlerToken);
    }

    @ApiOperation("获取运营商通话记录")
    @GetMapping("/getOperator")
    public Response getOperator(String userKey) {
        return xingPanRiskOtherService.getOperator(userKey);
    }

    @ApiOperation("获取运营商通话记录")
    @GetMapping("/getOperatorReport")
    public Response getOperatorReport(String userKey) {
        return xingPanRiskOtherService.getOperatorReport(userKey);
    }

}
